<template>
  <div class="ok">
      <group title="找回支付密码">
        <!-- <x&#45;input title="请输入手机号码" v&#45;model="Changepwd.postData.tradePassword"   placeholder="请输入新密码"></x&#45;input> -->



 <x-input title="发送验证码" placeholder="请输入验证码"   v-model="Changepwd.postData.validCode"  class="weui-vcode">
        <x-button slot="right" @click.native="sendValidCode"   type="primary" mini>发送验证码</x-button>
      </x-input>




          <!-- <x&#45;input title="请输入短信验证码" v&#45;model="Changepwd.postData.tradePassword" type="password"  placeholder="请输入新密码"></x&#45;input> -->
      </group>
      <x-input title="请输入新密码" v-model="Changepwd.postData.tradePassword"  placeholder="请输入新密码"></x-input>
      <x-input v-model="a" title="再次输入密码" placeholder="请输入新密码"></x-input>
      <x-button class="confirm" :disable="Changepwd.postData.tradePasswrod !==a" @click.native="gobtn" type="primary">提交</x-button></group>
      </group>
  </div>
</template>
<style>
  .confirm{
    width:80%;
    margin: 30px auto;
  }
  </style>
<script>
  import { Divider,XInput,XButton,Group } from 'vux'

  export default {
    data(){
      return {
        a:"",
        Changepwd:{
          actionName:"ResetTradePassword",
          url:'baseapi',
          postData: {
            "tradePassword":"", // 支付密码
            "validCode":"" // 手机验证码
          }
        },
      }
    },
    methods:{
      gobtn(){

        this.$store.commit('restful_api',this.Changepwd)
      }
    },
    components:{
      Divider,
      XInput,
      XButton,Group
    }
  }
  </script>
